<!DOCTYPE html>
<html>
<head>
    <title>
        业务进入账管理
    </title>
    <style type="text/css">
        .li div{
            float: left;
            width:100px;
        }

    </style>
</head>
<body>
<div style="width: 1000px;text-align: center;">
<form action="/finance/findBusinessAll" method="post">
    <table width="1000px">
        <tr>
            <td>
                记账事项：   <select name="itemsid">
                    <option value="-1">请选择</option>
                    <#list itemList as item>
                    <option value="${item.itemsid}"
                    <#if (itemsid==item.itemsid)>
                        selected
                    </#if>
                    >
                        ${item.itemsname}
                    </option>
                    </#list>
                </select>
            </td>
            <td>
                关系人：<input type="text" name="relation" value="${relation}"/>
            </td>
            <td>
                记账时期:<input type="date" name="recorddate" value="${recorddate}"/>
            </td>
            <td>
                进/出账:<select name="account" >
                    <option value="-1">请选择</option>
                    <option value="0"
                    <#if (account==0)>
                        selected
                    </#if>
                    >出账</option>
                    <option value="1"
                        <#if (account==1)>
                            selected
                            </#if>
                    >进账</option>
                </select>
            </td>
            <td>
                <input type="submit" value="查询">
            </td>
        </tr>
    </table>
</form>
    <table width="1200px" border="1" cellspacing="0" cellpadding="0">

        <tr>
            <th>编号</th>
            <th>记账事项</th>
            <th>业务日期</th>
            <th>关系人</th>
            <th>往来单位</th>
            <th>事由</th>
            <th>进账</th>
            <th>出账</th>
            <th>记录人</th>
            <th>记录时间</th>
            <th>相关车辆</th>
            <th>审核</th>
            <th>交易确认</th>
            <th>操作</th>
        </tr>
        <#list pageinfo.list as business>
            <tr>
                <td>${business_index+1}</td>
                <td>${business.matter.itemsname}</td>
                <td>${business.businessdate?string("yyyy-MM-dd")}</td>
                <td>${business.relation}</td>
                <td>${business.workunit}</td>
                <td>${business.item}</td>
                <td>
                <#if business.account==1> ${business.money}</#if>
                </td>
                <td>
                    <#if business.account==0> ${business.money}</#if>
                </td>
                <td>${business.recordName}</td>
                <td>${business.recorddate?date}</td>
                <td>${business.vehicle.vename}</td>
                <td>
                    <#if business.check==0>
                        审核
                    </#if>
                    <#if business.check==1>
                        已审核
                    </#if>
                </td>
                <td>
                    <a href="/finance/updatecheck?bid=${business.bid}">
                    <#if business.affirm==0>
                        确认
                    </#if>
                    </a>
                    <#if business.affirm==1>
                        已确认
                    </#if>
                </td>
                <td><a href="/finance/findbybid?bid=${business.bid}">编辑</a> &nbsp;<a href="/finance/udpatestatu?bid=${business.bid}"> 删除</a></td>
            </tr>
       </#list>
    </table>
    <div class="what">
        <div class="li">

           <a href="/finance/findBusinessAll?pageindex=1&itemsid=${itemsid}&relation=${relation}&account=${account}&recorddate=${recorddate}">首页</a>
            <a href="/finance/findBusinessAll?pageindex=
               <#if (pageinfo.prePage==0)>
                   1
                   <#else>
                   ${pageinfo.prePage}
               </#if>
               &itemsid=${itemsid}&relation=${relation}&account=${account}&recorddate=${recorddate}
               "

            >上一页
            </a>
            <a href="/finance/findBusinessAll?pageindex=
            <#if (pageinfo.nextPage==0)>
                ${pageinfo.pages}
             <#else>
                ${pageinfo.nextPage}
              </#if>
               &itemsid=${itemsid}&relation=${relation}&account=${account}&recorddate=${recorddate}
                    "
            >
                下一页
            </a>
            <a href="/finance/findBusinessAll?pageindex=${pageinfo.pages} &itemsid=${itemsid}&relation=${relation}&account=${account}&recorddate=${recorddate}"> 尾页</a>
            第${pageinfo.pageNum}页
            共${pageinfo.pages}页
            共${pageinfo.total}条
            &nbsp;&nbsp;&nbsp;
            进账合计:${sum1?string.currency}&nbsp;&nbsp;&nbsp;出账合计:${sum?string.currency}
            <p>进账总合计：${summation?string.currency} &nbsp;&nbsp;出账总合计: ${chuzhang?string.currency}  </p>
     </div>
    </div>

</div>
</body>
</html>